class Solution {
public:
    int Fibonacci(int n) {
        if (n == 1 || n == 2) return 1;
        int i = 2;
        int a = 0, b = 1, c = 1;
        while (i++ < n) {
            a = b + c;
            c = b; 
            b = a;
        }
        return a;
    }
};